package com.atmilan.quartz.utils;

import java.io.BufferedReader;
import java.io.FileInputStream;
import java.io.IOException;
import java.io.InputStreamReader;

public class FileUtil {

    public static void main(String[] args) throws IOException {
        System.out.println(getXmlData());
    }

    public static String getXmlData() throws IOException {
        BufferedReader br = null;
        String data = null;
        String xmlData = "";
        try {
            String fileName = "E:\\HIK-WORKSPACE\\hiku-server\\hiku-web\\src\\main\\resources\\test.txt";
            br= new BufferedReader(new InputStreamReader(new FileInputStream(fileName)));

            while ((data = br.readLine()) != null){
                xmlData += data;
            }
        }catch (Exception e){
            e.printStackTrace();
        }finally{
            br.close();
        }
        return xmlData;
    }

}
